//
//  ShareCenterServiceHandler.h
//  ShareCenter
//
//  Created by yutao on 14-2-23.
//  Copyright (c) 2014年 yutao. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "ShareClientType.h"
#import "SNShareServiceNotification.h"
@class  ShareClientUserInfo;
@class ShareClientOAuthInfo;

@interface ShareCenterServiceHandler : NSObject
+ (SNShareClientType)serviceTypeForNotification:(NSNotification *)note;

/**
 * @return    返回字典类型
 *
 * 方法+ (void)postNotificationName:(NSString *)name
 *                                           serviceType:(SNShareServiceType)type
 *                                              userInfo:(NSDictionary *)userInfo
 * 里的userInfo
 */
+ (NSDictionary *)userInfoForNotification:(NSNotification *)note;

/**
 * 接收到SNShareServiceDidLoadUserInfoNotification通知时，
 * 通过此方法获取SNShareServiceUserInfo
 *
 * @return    返回用户信息（SNShareServiceUserInfo）类型
 *
 * 方法 + (void)postNotificationName:(NSString *)name
 *                      serviceType:(SNShareServiceType)type
 *             shareServiceUserInfo:(SNShareServiceUserInfo *)userInfo
 * 里的shareServiceUserInfo
 */
+ (ShareClientUserInfo *)shareServiceUserInfoForNotification:(NSNotification *)note;
+ (ShareClientOAuthInfo *)shareServiceOauthInfoForNotification:(NSNotification *)note;

+ (void)postNotificationName:(NSString *)name
                      object:(id)object
                 serviceType:(SNShareClientType)type
                    userInfo:(NSDictionary *)userInfo;

+ (void)postNotificationName:(NSString *)name
                 serviceType:(SNShareClientType)type
                    userInfo:(NSDictionary *)userInfo;

+ (void)postNotificationName:(NSString *)name
                 serviceType:(SNShareClientType)type;

// 用户信息通知
+ (void)postNotificationName:(NSString *)name
                      object:(id)object
                 serviceType:(SNShareClientType)type
        shareServiceUserInfo:(ShareClientUserInfo *)userInfo;

+ (void)postNotificationName:(NSString *)name
                      object:(id)object
                 serviceType:(SNShareClientType)type
        shareServiceOauthInfo:(ShareClientOAuthInfo *)userInfo;

+ (void)postNotificationName:(NSString *)name
                 serviceType:(SNShareClientType)type
        shareServiceUserInfo:(ShareClientUserInfo *)userInfo;

+ (void)postNotificationName:(NSString *)name
                 serviceType:(SNShareClientType)type
        shareServiceOauthInfo:(ShareClientOAuthInfo *)userInfo;
@end
